package com.ruoyi.AI;

import lombok.Data;

import java.util.Arrays;
import java.util.List;

/**
 * @author Ryan
 * @version 1.0
 * @date 2024/5/9 11:29
 */
@Data
public class ChatCompletionResponse {

    private String id;
    private String object;
    private long created;
    private String model;
    private List<ChatCompletionChoice> choices;
    private Usage usage;

    public List<ChatCompletionChoice> getChoices() {
        if (choices == null) {
            return Arrays.asList();
        }
        return choices;
    }
}
